home *** CD-ROM | disk | FTP | other *** search
- #
- # MAKEFILE
- # Sample Code Class Libraries
- #
- # Copyright (c)1993 Microsoft Corporation, All Rights Reserved
- #
- # Kraig Brockschmidt, Software Design Engineer
- # Microsoft Systems Developer Relations
- #
- # Internet : kraigb@microsoft.com
- # Compuserve: >INTERNET:kraigb@microsoft.com
- #
-
- #Add '#' to the next line for "noisy" operation
- !CMDSWITCHES +s
-
- #
- #Compiler flags
- #Use "SET RETAIL=1" from MS-DOS to compile non-debug version.
- #
- !ifndef RETAIL
- CFLAGS = -c -nologo -Od -AM -Zipe -G2s -W3 -GA -GEs
- DEFS = -DSTRICT -DDEBUG
- !else
- CFLAGS = -c -nologo -Oas -AM -Zpe -G2s -W3 -GA -GEs
- DEFS = -DSTRICT
- !endif
-
-
- !ifdef SDI
- DOC = -DSDI
- TARGET = classSDI
- DIR = SDI
- SRC_DIR = ..
- !else
- DOC = -DMDI
- TARGET = classMDI
- DIR = MDI
- SRC_DIR = ..
- !endif
-
-
- .SUFFIXES: .h .obj .exe .cpp .res .rc
-
- goal: cd_build $(TARGET).lib cd_src
-
- cd_build:
- cd $(DIR)
-
- cd_src:
- cd ..
-
- clean:
- cd $(DIR)
- del *.obj
- del *.lib
- cd ..
-
-
- INCLS = $(SRC_DIR)\classlib.h $(SRC_DIR)\classres.h
-
- OBJS1 = cstrtabl.obj
- OBJS2 = cwindow.obj cframe.obj framewin.obj
- OBJS3 = cclient.obj cdocumnt.obj docwin.obj
- OBJS4 = cgizbar.obj cstastrp.obj
- OBJS = $(OBJS1) $(OBJS2) $(OBJS3) $(OBJS4)
-
-
- #####
-
- {$(SRC_DIR)}.cpp{}.obj:
- echo +++++++++
- echo Compiling $*.cpp
- cl $(CFLAGS) $(DEFS) $(DOC) ..\$*.cpp
-
-
- #Create a library
- $(TARGET).lib : $(OBJS)
- echo ++++++++++
- echo Creating $@
- del $(TARGET).LIB
- lib @..\$(TARGET).lrf
-
-
- ##### Dependencies #####
-
- cstrtabl.obj : $(SRC_DIR)\cstrtabl.cpp $(INCLS)
-
- cwindow.obj : $(SRC_DIR)\cwindow.cpp $(INCLS)
-
- cframe.obj : $(SRC_DIR)\cframe.cpp $(INCLS)
- framewin.obj : $(SRC_DIR)\framewin.cpp $(INCLS)
-
- cclient.obj : $(SRC_DIR)\cclient.cpp $(INCLS)
-
- cdocumnt.obj : $(SRC_DIR)\cdocumnt.cpp $(INCLS)
- docwin.obj : $(SRC_DIR)\docwin.cpp $(INCLS)
-
- cgizbar.obj : $(SRC_DIR)\cgizbar.cpp $(INCLS)
- cstastrp.obj : $(SRC_DIR)\cstastrp.cpp $(INCLS)
-